# Maintainer: Tim Meusel <tim@bastelfreak.de>
# Contributor: Christian Hesse <mail@eworm.de>
# Contributor: Thomas S Hatch <thatch45 (at) Gmail (dot) com>

pkgname=virt-what
pkgver=1.25
pkgrel=1
license=('GPL')
arch=('loong64' 'x86_64')
depends=('dmidecode')
pkgdesc='A small program that prints out a list of facts about a virtual machine'
url='http://people.redhat.com/~rjones/virt-what/'
validpgpkeys=('F7774FB1AD074A7E8C8767EA91738F73E1B768A0')
source=("https://people.redhat.com/~rjones/virt-what/files/${pkgname}-${pkgver}.tar.gz"{,.sig})
sha512sums=('0147b4b44ae0ee685977aa34dfa9bf30ae8e0eb31b7a6d5c0097d16f830fa6fb6afd7156964fc79f3fd5e82b2f68d921fd5306245cc63a2140f6dddc7fdd0e98'
            'SKIP')

build() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  ./configure
  sed -i '/^sbindir/c sbindir = /usr/bin' Makefile
  make
}

package() {
  cd "${srcdir}/${pkgname}-${pkgver}"

  make libexecdir=/usr/bin prefix=/usr DESTDIR=${pkgdir} install
}
